import {defineStore} from "pinia";
import {ref} from "vue";

export const useUserStore = defineStore('user', () => {
    //用户id,token
    const account = ref({})
    //重置用户信息
    const reset = () => {
        account.value = {}
        localStorage.clear()
    }

    return {account, reset}
}, {
    persist: true
})